{extend name="common/base" /}

{block name="body"}
<div class="layui-tab layui-tab-brief">
    <ul class="layui-tab-title">
        {volist name="tabs" id="vo"}
        <li {if $tab === $key }class="layui-this" {/if}>
        <a href="{$vo.href}">{$vo.title}</a>
        </li>
        {/volist}
    </ul>
    <div class="layui-tab-content" style="margin-top: 10px;">
        <div class="layui-tab-item layui-show">
            <table class="layui-table" lay-skin="line">
                <colgroup>
                    <col width="150">
                    <col width="90">
                    <col width="90">
                    <col width="90">
                    <col >
                    <col >
                    <col width="80">
                </colgroup>
                <thead>
                </thead>
                <tbody>
                <tr>
                    <td>模版ID</td>
                    <td>模版名称</td>
                    <td>主行业</td>
                    <td>副行业</td>
                    <td>模版内容</td>
                    <td>样例</td>
                    <td>操作</td>
                </tr>
                {volist name="data_list" id="vo"}
                <tr>
                    <td>{$vo.template_id}</td>
                    <td>{$vo.title}</td>
                    <td>{$vo.primary_industry}</td>
                    <td>{$vo.deputy_industry}</td>
                    <td>{:str_replace("\\n", "<br>", $vo.content)}</td>
                    <td>{:str_replace("\\n", "<br>", $vo.example)}</td>
                    <td>
                        <a href="{:url('add', ['template_id' => $vo['template_id']])}" class="layui-btn  layui-btn-sm">创建消息</a>
                    </td>
                </tr>
                {/volist}
                </tbody>
            </table>
        </div>
    </div>
</div>
{/block}